#pragma once
#include "../stdafx.h"
#include "./RenderManager.h"
#include "../game/Manager.h"
#include "../scene/Menu.h"
#include "../scene/World.h"
#include "../game/FigureObject.h"

#define MAX 32

#define MOUSE	0
#define TEST	31
namespace SLG
{
	extern LPDIRECT3DDEVICE9 g_pd3dDevice; 
	class render
	{
	public:
		render(void);
		~render(void);

		void AddList(RenderManager*);

		HRESULT RenderList(DWORD t);
		void Init();
		
		void AddFigure(FigureObject*);
		void AddMenu(Menu*);
		void AddWorld(World*);

		HRESULT Render2DWorld();

		void BeginRender();
		void EndRender();

		//HRESULT RenderMouse(D3DXVECTOR2);

		void TestInit(AABB*);
		void RenderTest();

		ID3DXSprite*		m_pSprite;
		RenderManager* m_rManager;
		D3DXMATRIX ObjWorldMatrices;
		ID3DXMesh* Teapot;
		LPDIRECT3DTEXTURE9      m_pTexture[MAX]; // Our texture
		LPDIRECT3DVERTEXBUFFER9 m_pVertices[MAX];
		LPDIRECT3DINDEXBUFFER9 m_pIndex[MAX];
		Menu* m_menu;
		World* m_world;
	};
}